<template>
  <div id="app">
    <div>
      <!-- 头部 -->
      <mt-header fixed title="贼牛逼的项目"></mt-header>
      <!-- 中间的内容 -->
      <transition name="ts">
        <router-view></router-view>
      </transition>
      
      <!-- 底部 -->
      <nav class="mui-bar mui-bar-tab">
        <router-link class="mui-tab-item-xie " to="/home">
          <span class="mui-icon mui-icon-home"></span>
          <span class="mui-tab-label">首页</span>
        </router-link>
        <router-link class="mui-tab-item-xie " to="/email">
          <span class="mui-icon mui-icon-email">
          </span>
          <span class="mui-tab-label">消息</span>
        </router-link>
        <router-link class="mui-tab-item-xie " to="/cart">
          <span class="mui-icon mui-icon-extra mui-icon-extra-cart" >
             <span class="mui-badge" id="nvn">{{$store.getters.allCount}}</span>
          </span>
          <span class="mui-tab-label">购物车</span>
        </router-link>
        <router-link class="mui-tab-item-xie " to="/search">
          <span class="mui-icon mui-icon-search"></span>
          <span class="mui-tab-label">搜索</span>
        </router-link>
      </nav>
    </div>
  </div>
</template>

<script>
export default {};
</script>

<style >
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
li {
  list-style: none;
}
#app {
  padding-top: 40px;
  padding-bottom: 60px;
  overflow-x: hidden;
}

.ts-enter {
  transform: translateX(100%);
  opacity: 0;
}
.ts-leave-to {
   transform: translateX(-100%);
   opacity: 0;
}
.ts-enter-active,
.ts-leave-active {
  transition:  all .5s ease;
}
.ts-leave-active {
  position: absolute;
}



 .mui-bar-tab .mui-tab-item-xie.mui-active {
    color: #007aff;
  }
  .mui-bar-tab .mui-tab-item-xie {
    display: table-cell;
    overflow: hidden;
    width: 1%;
    height: 50px;
    text-align: center;
    vertical-align: middle;
    white-space: nowrap;
    text-overflow: ellipsis;
    color: #929292;
  }
  .mui-bar-tab .mui-tab-item-xie .mui-icon {
    top: 3px;
    width: 24px;
    height: 24px;
    padding-top: 0;
    padding-bottom: 0;
  }
  .mui-bar-tab .mui-tab-item-xie .mui-icon ~ .mui-tab-label {
    font-size: 11px;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
  }
</style>
